'''urllib_get请求urlencode处理多参数浏览器编解码
作用：将get请求入参字符转为编码           '''
import urllib.parse

# 示例： https://www.baidu.com/s?wd=张三&sex=男
getParam ={
    "wd":"张三",
    "sex":"男"
}
get_param = urllib.parse.urlencode(getParam)
print(get_param)

url = 'https://www.baidu.com/s?'+get_param
print(url)  #结果： https://www.baidu.com/s?wd=%E5%BC%A0%E4%B8%89&sex=%E7%94%B7